<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>列表渲染-更新时的一个问题</title>
    <script type="text/javascript" src="../js/vue.js"></script>
</head>

<body>

    <div id="root">
        <h2>学校名称：{{name}}</h2>
        <h2>学校地址：{{address}}</h2>
    </div>
</body>
<script type="text/javascript">

    const vm = new Vue({
        el: '#root',
        data: {
            name: '北京大学',
            address: '北京',
            student: {
                name: '张三',
                age: {
                    trueAge: 18,
                    falseAge: 20
                },
                friends: [
                    { name: '李四', age: 18 },
                    { name: '小七', age: 15 },
                ]
            }
        }
    })
</script>

</html>